home *** CD-ROM | disk | FTP | other *** search
- Path: ix.netcom.com!netnews
- From: jdmorris@ix.netcom.com (Jason D. Morris)
- Newsgroups: comp.lang.c++
- Subject: Re: strstream destruction
- Date: Sat, 30 Mar 1996 03:34:39 GMT
- Organization: Netcom
- Message-ID: <315cab85.3232077@nntp.ix.netcom.com>
- References: <315AD92C.726D@itd.ssb.com>
- NNTP-Posting-Host: pon-mi2-25.ix.netcom.com
- X-NETCOM-Date: Fri Mar 29 7:33:46 PM PST 1996
- X-Newsreader: Forte Agent .99d/32.182
-
- > i plan to use ostrstream to create some strings , i would
- >like to pass the string created as a char * by calling ostrstream.str().
- >how do i free the memory allocated can i just call delete on the char *
- >returned by ostrstream.str().
-
- Calling the ostrstream::str() freezes the dynamic buffer. To unfreeze
- the buffer, call ostrstream::freeze( 0 ). The stream will take care
- of deallocating the buffer for you.
-
- Jason
-
-